package spring.bean;

import org.springframework.beans.factory.annotation.Value;

public class Mali {
    private String name;
    @Value("${test.className}")
    private String className;
    public void hello(){
        System.out.println("mali !"+name);
    }
    public void init(){
        System.out.println("我是对象初始化时要做的事情！");
    }
    public void sayHello() {
        System.out.println("hello"+className);
    }
    public void destroy(){
        System.out.println("我是对象销毁时要做的事情！");
    }
    public void setName(String name) {
        this.name = name;
    }
}
